-
Notifications
You must be signed in to change notification settings - Fork 77
[GEN][ZH] Remove unnecessary NULL pointer tests in InGameUI #1092
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
0584122
to
e4b5340
Compare
|
||
// delete the animation instance | ||
deleteInstance(wad->m_anim); | ||
WorldAnimationData *wad = *it; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
i would change these up for while loops since the iterators are being erased and updated within the loop body.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I will leave it as is too keep the change difference small.
if( mData1 == TRUE ) | ||
*(Bool *)mData2 = FALSE; | ||
break; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Snuck into this PR but should be okay. i wonder if this fixes anything user focused.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oh. That was not meant to be here...
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fixed
This change removes unnecessary NULL pointer tests in InGameUI and makes the compiler happy.
Unnecessary because
m_worldAnimationList
will not accept adding null elements and will not write null to its elements.